param( [string] $RootDir )

begin
{
    if ($RootDir -ne '')
    {
	   $RootPath = ([System.io.DirectoryInfo] $RootDirItem = Get-Item $RootDir).FullName
    }
    else
    {
        $RootPath = ""
    }
}

process
{
	if ($_ -is [system.io.fileinfo])
	{
		$_ | Attach-Checksum -IncludeFileLength | Attach-RelativePath $RootPath | Select Checksum,RelativePath
	}
}
